package com.jt.demo3;

import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/axios")
@CrossOrigin   //跨域问题
public class AxiosPost {
    //6. 将json串转化java @RequestBody     post必须 将返回数据转json @ResponseBody
    @ResponseBody
    @PostMapping("/saveUser")
    public User saveUser1(
            @RequestBody User user){
        return user;
    }
}
